<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>页码切换</title>
    <link rel="stylesheet" href="../css/page.css">
</head>
<script src="../../js/axios.js"></script>
<body>
    <div class="page" id="page">
        
    </div>
</body>
<script src="../js/page.js"></script>
<script>
    new Page({
        ele: "#page",
        data: {
            total: 111,//数据总数是100
            shownum: 10,//表示每页显示10条数据
            showpage:5,//表示连续的页码数为5
        },
        methods: {
            cb: (index) => {
                console.log(`去请求第${index}页的数据`);
                
            }
        }
    });
</script>

</html>